import matplotlib.pyplot as plt


def example_plot(ax):
    ax.plot([1, 2])
    ax.set_xlabel('x-label', fontsize=12)
    ax.set_ylabel('y-label', fontsize=12)
    ax.set_title('Title', fontsize=14)


fig = plt.figure(constrained_layout=False)

import matplotlib.gridspec as gridspec

gs0 = gridspec.GridSpec(1, 1, figure=fig)

gs1 = gridspec.GridSpecFromSubplotSpec(1, 1, subplot_spec=gs0[0])
for n in range(1):
    print(n)
    ax = fig.add_subplot(gs1[n])
    print(ax)
    example_plot(ax)


# gs2 = gridspec.GridSpecFromSubplotSpec(1, 1, subplot_spec=gs0[1])
# for n in range(1):
#     ax = fig.add_subplot(gs2[n])
#     example_plot(ax)
plt.subplots_adjust(wspace=0.3, hspace=0.5)
plt.show()